package Ch16;

import java.io.FileInputStream;
import java.io.InputStream;
import java.util.Scanner;

public class ByteReadWay {
	public static void main(String[] args) throws Exception {
		InputStream in = 
				new FileInputStream("c:\\temp\\aaa.txt");
		Scanner scanner = new Scanner(in);
		while(true){
			try {
				String str = scanner.nextLine();
				System.out.println(str);
			} catch (Exception e) {
				break;
			}//end catch
		}//end while
		in.close();
	}
}
